<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>XIXIA CMS 数据库设计</title>
<link rel="stylesheet" href="../css/prettify.css" type="text/css" />
<script type="text/javascript" src="../js/prettify.js"></script>
</head>

<body onload="prettyPrint()">
<h1> <span>XIXIA CMS</span> 数据库设计</h1>
<hr />
<dl>
  <dt>xixia_options</dt>
  <dd>包含XiXia设置信息</dd>
  <dt>xixia_site_archives</dt>
  <dd>包含网站文档及树</dd>
  <dt>xixia_site_blocks</dt>
  <dd>包含静态HTML</dd>
  <dt>xixia_site_fields</dt>
  <dd>包含后台视图及数据库操作数组</dd>
  <dt>xixia_site_keywords</dt>
  <dd>包含网站关键词</dd>
  <dt>xixia_site_modules</dt>
  <dd>包含文档类型模块</dd>
  <dt>xixia_site_snippets</dt>
  <dd>包含动态PHP</dd>
  <dt>xixia_site_templates</dt>
  <dd>包含网站模板</dd>
</dl>
<hr />
<pre class="prettyprint linenums">
-- phpMyAdmin SQL Dump
-- version 2.11.9.2
-- http://www.phpmyadmin.net
--
-- 主机: localhost
-- 生成日期: 2010 年 10 月 01 日 03:34
-- 服务器版本: 5.0.67
-- PHP 版本: 5.2.6

SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";

--
-- 数据库: `xixia`
--

-- --------------------------------------------------------

--
-- 表的结构 `xixia_options`
--

CREATE TABLE IF NOT EXISTS `xixia_options` (
  `option_name` varchar(50) collate utf8_unicode_ci NOT NULL,
  `option_value` varchar(250) collate utf8_unicode_ci NOT NULL,
  UNIQUE KEY `setting_name` (`option_name`),
  KEY `setting_name_2` (`option_name`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci COMMENT='包含XiXia设置信息';

--
-- 导出表中的数据 `xixia_options`
--

INSERT INTO `xixia_options` (`option_name`, `option_value`) VALUES
('settings_version', '1.1'),
('date_format', '%m-%d-%Y'),
('time_format', '%I:%M %p'),
('server_offset_time', '0'),
('server_protocol', 'http'),
('manager_language', 'english'),
('etomite_charset', 'UTF-8'),
('site_name', 'My Etomite Site'),
('site_start', '1'),
('error_page', '3'),
('site_status', '1'),
('site_unavailable_message', 'The site is currently unavailable'),
('track_visitors', '1'),
('resolve_hostnames', '1'),
('top_howmany', '10'),
('default_template', '2'),
('publish_default', '1'),
('search_default', '1'),
('cache_default', '1'),
('syncsitecheck_default', '1'),
('showinmenu_default', '1'),
('friendly_urls', '0'),
('friendly_url_prefix', 'p_'),
('friendly_url_suffix', '.html'),
('friendly_alias_urls', '0'),
('use_udperms', '0'),
('use_uvperms', '0'),
('access_denied_message', ''),
('udperms_allowroot', '0'),
('use_mgr_logging', '1'),
('max_attempts', '3'),
('use_captcha', '0'),
('captcha_words', 'Array,BitCode,Chunk,Document,Etomite,Forum,Index,Javascript,Keyword,MySQL,Parser,Query,Random,Snippet,Template,Website'),
('signupemail_message', 'Hi! \r\n\r\nHere are your login details for Etomite:\r\n\r\nUsername: %s\r\nPassword: %s\r\n\r\nOnce you log into Etomite, you can change your password.\r\n\r\nRegards,\r\nThe Management'),
('emailsender', 'you@yourdomain.com'),
('emailsubject', 'Your Etomite login details'),
('number_of_logs', '100'),
('number_of_messages', '30'),
('show_doc_data_preview', '1'),
('use_doc_editor', '1'),
('which_editor', '1'),
('strict_editor', '1'),
('strip_base_href', '1'),
('cm_plugin', '0'),
('to_plugin', '0'),
('xp_Stylist', '0'),
('xp_Stylist_path', 'http://127.0.0.1/etomite/assets/site/example.css'),
('im_plugin', '1'),
('im_plugin_base_dir', ''),
('im_plugin_base_url', 'http://127.0.0.1/etomite/assets/images/'),
('fm_plugin', '1'),
('fm_plugin_base_url', 'http://127.0.0.1/etomite'),
('fm_plugin_document_url', 'http://127.0.0.1/etomite/assets/documents'),
('fm_path', '/assets/documents'),
('fm_exclude', '.,..,cgi-bin,aspnet_client,index.php,index.html'),
('fm_upload_files', 'jpg,gif,png,ico,txt,php,html,htm,xml,js,css,cache,zip,gz,rar,z,tgz,tar,htaccess,bmp,mp3,wav,au,wmv,avi,mpg,mpeg,pdf,psd'),
('tiny_css_path', ''),
('tiny_css_selectors', ''),
('use_code_editor', '0'),
('code_highlight', '0'),
('dumpSQL', '0'),
('dumpSnippets', '0'),
('allow_embedded_php', '0'),
('strip_image_paths', '0'),
('filemanager_path', ''),
('upload_files', 'jpg,gif,png,ico,txt,php,html,htm,xml,js,css,cache,zip,gz,rar,z,tgz,tar,htaccess,bmp,mp3,wav,au,wmv,avi,mpg,mpeg,pdf,psd'),
('inlineview_files', 'txt,php,html,htm,xml,js,css'),
('view_files', 'jpg,gif,png,ico'),
('edit_files', 'txt,php,html,htm,xml,js,css'),
('exclude_paths', '.,..,cgi-bin,manager'),
('maxuploadsize', ''),
('useNotice', '1'),
('manager_layout', '1');

-- --------------------------------------------------------

--
-- 表的结构 `xixia_site_archives`
--

CREATE TABLE IF NOT EXISTS `xixia_site_archives` (
  `id` int(10) NOT NULL auto_increment,
  `type` varchar(20) character set utf8 collate utf8_unicode_ci NOT NULL default 'document',
  `Content-Type` varchar(50) character set utf8 collate utf8_unicode_ci NOT NULL default 'text/html',
  `pagetitle` varchar(100) character set utf8 collate utf8_unicode_ci NOT NULL default '',
  `longtitle` varchar(255) character set utf8 collate utf8_unicode_ci NOT NULL default '',
  `description` varchar(255) character set utf8 collate utf8_unicode_ci NOT NULL default '',
  `alias` varchar(100) character set utf8 collate utf8_unicode_ci default '',
  `published` int(1) NOT NULL default '0',
  `pub_date` int(20) NOT NULL default '0',
  `unpub_date` int(20) NOT NULL default '0',
  `parent` int(10) NOT NULL default '0',
  `isfolder` int(1) NOT NULL default '0',
  `content` mediumtext character set utf8 collate utf8_unicode_ci NOT NULL,
  `richtext` tinyint(1) NOT NULL default '1',
  `template` int(10) NOT NULL default '1',
  `menuindex` int(10) NOT NULL default '0',
  `searchable` int(1) NOT NULL default '1',
  `cacheable` int(1) NOT NULL default '1',
  `createdby` int(10) NOT NULL default '0',
  `createdon` int(20) NOT NULL default '0',
  `editedby` int(10) NOT NULL default '0',
  `editedon` int(20) NOT NULL default '0',
  `deleted` int(1) NOT NULL default '0',
  `deletedon` int(20) NOT NULL default '0',
  `deletedby` int(10) NOT NULL default '0',
  `authenticate` int(1) NOT NULL default '0',
  `showinmenu` int(1) NOT NULL default '1',
  PRIMARY KEY  (`id`),
  KEY `parent` (`parent`),
  FULLTEXT KEY `archives_idx` (`pagetitle`,`description`,`content`),
  FULLTEXT KEY `pagetitle` (`pagetitle`)
) ENGINE=MyISAM  DEFAULT CHARSET=utf8 COMMENT='包含网站文档树' AUTO_INCREMENT=1 ;

--
-- 导出表中的数据 `xixia_site_archives`
--


-- --------------------------------------------------------

--
-- 表的结构 `xixia_site_blocks`
--

CREATE TABLE IF NOT EXISTS `xixia_site_blocks` (
  `id` int(10) NOT NULL auto_increment,
  `name` varchar(50) character set utf8 collate utf8_unicode_ci NOT NULL default '',
  `description` varchar(255) character set utf8 collate utf8_unicode_ci NOT NULL default '静态片段',
  `content` mediumtext character set utf8 collate utf8_unicode_ci NOT NULL,
  `locked` tinyint(4) NOT NULL default '0',
  PRIMARY KEY  (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COMMENT='包含静态HTML。' AUTO_INCREMENT=1 ;

--
-- 导出表中的数据 `xixia_site_blocks`
--


-- --------------------------------------------------------

--
-- 表的结构 `xixia_site_fields`
--

CREATE TABLE IF NOT EXISTS `xixia_site_fields` (
  `id` int(10) NOT NULL auto_increment,
  `model` varchar(50) NOT NULL,
  `table` varchar(50) NOT NULL,
  `field_name` varchar(50) default NULL,
  `field_type` enum('VARCHAR','TINYINT','TEXT','DATE','SMALLINT','MEDIUMINT','INT','BIGINT','FLOAT','DOUBLE','DECIMAL','DATETIME','TIMESTAMP','TIME','YEAR','CHAR','TINYBLOB','TINYTEXT','BLOB','MEDIUMBLOB','MEDIUMTEXT','LONGBLOB','LONGTEXT','ENUM','SET','BIT','BOOL','BINARY','VARBINARY') NOT NULL,
  `field_lengthorvalues` varchar(255) default NULL,
  `field_null` enum('NOT NULL','NULL') NOT NULL,
  `field_default` varchar(255) default NULL,
  `field_index` set('PRIMARY KEY','KEY','UNIQUE KEY','FULLTEXT KEY') default NULL,
  `input_label` varchar(50) default NULL,
  `input_type` enum('button','checkbox','file','hidden','password','radio','reset','select','submit','text','textarea') NOT NULL,
  `input_name` varchar(50) default NULL,
  `input_value` varchar(255) default NULL,
  `input_id` varchar(50) default NULL,
  `input_description` varchar(255) character set utf8 collate utf8_unicode_ci default NULL,
  `input_extra` varchar(255) default NULL,
  PRIMARY KEY  (`id`),
  KEY `modelid` (`model`)
) ENGINE=MyISAM  DEFAULT CHARSET=utf8 AUTO_INCREMENT=28 ;

--
-- 导出表中的数据 `xixia_site_fields`
--

INSERT INTO `xixia_site_fields` (`id`, `model`, `table`, `field_name`, `field_type`, `field_lengthorvalues`, `field_null`, `field_default`, `field_index`, `input_label`, `input_type`, `input_name`, `input_value`, `input_id`, `input_description`, `input_extra`) VALUES
(1, 'archives', 'site_archives', 'id', 'INT', '10', 'NOT NULL', '', NULL, '档案ID', 'hidden', 'NULL', '', 'id', '所有类型文档的共用ID', NULL),
(2, 'archives', 'site_archives', 'archiveType', 'VARCHAR', '20', 'NOT NULL', 'document', NULL, '档案类型', 'select', 'NULL', '', 'NULL', 'NULL', NULL),
(3, 'archives', 'site_archives', 'contentType', 'VARCHAR', '50', 'NOT NULL', 'text/html', NULL, '页面类型', 'select', 'NULL', '', 'NULL', 'NULL', NULL),
(4, 'archives', 'site_archives', 'pagetitle', 'VARCHAR', '100', 'NOT NULL', '', NULL, '档案标题', 'text', 'NULL', '', 'NULL', 'NULL', NULL),
(5, 'archives', 'site_archives', 'longtitle', 'VARCHAR', '255', 'NOT NULL', '', NULL, '档案副标题', 'text', 'NULL', '', 'NULL', 'NULL', NULL),
(6, 'archives', 'site_archives', 'description', 'VARCHAR', '255', 'NOT NULL', '', NULL, '档案描述', 'hidden', 'NULL', '', 'id', '所有类型文档的共用ID', NULL),
(7, 'archives', 'site_archives', 'alisa', 'VARCHAR', '100', 'NOT NULL', '', NULL, 'URL别名', 'select', 'NULL', 'name:text/html', 'NULL', 'NULL', NULL),
(8, 'archives', 'site_archives', 'published', 'TINYINT', '1', 'NOT NULL', '', NULL, '是否发布', 'select', 'NULL', '', 'NULL', 'NULL', NULL),
(9, 'archives', 'site_archives', 'pub_date', 'INT', '20', 'NOT NULL', '', NULL, '定时发布', 'text', 'NULL', '', 'NULL', 'NULL', NULL),
(10, 'archives', 'site_archives', 'unpub_date', 'INT', '20', 'NOT NULL', '', NULL, '定时撤回', 'text', 'NULL', '', 'NULL', 'NULL', NULL),
(11, 'archives', 'site_archives', 'parent', 'INT', '10', 'NOT NULL', '', NULL, '所属栏目', '', '', '', '', '', NULL),
(12, 'archives', 'site_archives', 'isfolder', 'TINYINT', '1', 'NOT NULL', '', NULL, '作为栏目', '', '', '', '', '', NULL),
(13, 'archives', 'site_archives', 'content', 'MEDIUMTEXT', '', 'NOT NULL', '', NULL, '档案内容', '', '', '', '', '', NULL),
(14, 'archives', 'site_archives', 'richtext', 'TINYINT', '1', 'NOT NULL', '', NULL, '可视化编辑', '', '', '', '', '', NULL),
(15, 'archives', 'site_archives', 'template', 'INT', '10', 'NOT NULL', '', NULL, '模板套用', '', '', '', '', '', NULL),
(16, 'archives', 'site_archives', 'menuindex', 'INT', '10', 'NOT NULL', '', NULL, '在菜单中显示', '', '', '', '', '', NULL),
(17, 'archives', 'site_archives', 'searchable', 'TINYINT', '1', 'NOT NULL', '', NULL, '允许搜索', '', '', '', '', '', NULL),
(18, 'archives', 'site_archives', 'cacheable', 'TINYINT', '1', 'NOT NULL', '', NULL, '允许缓存', '', '', '', '', '', NULL),
(19, 'archives', 'site_archives', 'createdby', 'INT', '10', 'NOT NULL', '', NULL, '', '', '', '', '', '', NULL),
(20, 'archives', 'site_archives', 'createdon', 'INT', '20', 'NOT NULL', '', NULL, '', '', '', '', '', '', NULL),
(21, 'archives', 'site_archives', 'editedby', 'INT', '10', 'NOT NULL', '', NULL, '', '', '', '', '', '', NULL),
(22, 'archives', 'site_archives', 'editedon', 'INT', '20', 'NOT NULL', '', NULL, '', '', '', '', '', '', NULL),
(23, 'archives', 'site_archives', 'deleted', 'TINYINT', '1', 'NOT NULL', '', NULL, '', '', '', '', '', '', NULL),
(24, 'archives', 'site_archives', 'deletedon', 'INT', '20', 'NOT NULL', '', NULL, '', '', '', '', '', '', NULL),
(25, 'archives', 'site_archives', 'deletedby', 'INT', '10', 'NOT NULL', '', NULL, '', '', '', '', '', '', NULL),
(26, 'archives', 'site_archives', 'authenticate', 'INT', '1', 'NOT NULL', '', NULL, '', '', '', '', '', '', NULL),
(27, 'archives', 'site_archives', 'showinmenu', 'TINYINT', '1', 'NOT NULL', '0', NULL, '在菜单中显示', '', '', '', '', '', NULL);

-- --------------------------------------------------------

--
-- 表的结构 `xixia_site_keywords`
--

CREATE TABLE IF NOT EXISTS `xixia_site_keywords` (
  `id` int(11) NOT NULL auto_increment,
  `keyword` varchar(40) character set utf8 collate utf8_unicode_ci NOT NULL default '',
  PRIMARY KEY  (`id`),
  UNIQUE KEY `keyword` (`keyword`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COMMENT='网站关键词列表。' AUTO_INCREMENT=1 ;

--
-- 导出表中的数据 `xixia_site_keywords`
--


-- --------------------------------------------------------

--
-- 表的结构 `xixia_site_modules`
--

CREATE TABLE IF NOT EXISTS `xixia_site_modules` (
  `id` int(10) NOT NULL,
  `name` varchar(50) character set utf8 collate utf8_unicode_ci NOT NULL,
  `table` varchar(255) character set utf8 collate utf8_unicode_ci NOT NULL,
  PRIMARY KEY  (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;

--
-- 导出表中的数据 `xixia_site_modules`
--


-- --------------------------------------------------------

--
-- 表的结构 `xixia_site_snippets`
--

CREATE TABLE IF NOT EXISTS `xixia_site_snippets` (
  `id` int(10) NOT NULL auto_increment,
  `name` varchar(50) character set utf8 collate utf8_unicode_ci NOT NULL default '',
  `description` varchar(255) character set utf8 collate utf8_unicode_ci NOT NULL default '动态片段',
  `content` mediumtext character set utf8 collate utf8_unicode_ci NOT NULL,
  `locked` tinyint(4) NOT NULL default '0',
  PRIMARY KEY  (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 PACK_KEYS=0 COMMENT='包含动态PHP。' AUTO_INCREMENT=1 ;

--
-- 导出表中的数据 `xixia_site_snippets`
--


-- --------------------------------------------------------

--
-- 表的结构 `xixia_site_templates`
--

CREATE TABLE IF NOT EXISTS `xixia_site_templates` (
  `id` int(10) NOT NULL auto_increment,
  `name` varchar(50) character set utf8 collate utf8_unicode_ci NOT NULL,
  `description` varchar(255) character set utf8 collate utf8_unicode_ci NOT NULL default '模板',
  `content` mediumtext character set utf8 collate utf8_unicode_ci NOT NULL,
  `locked` tinyint(4) NOT NULL default '0',
  PRIMARY KEY  (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 PACK_KEYS=0 COMMENT='包含网站模板。' AUTO_INCREMENT=1 ;

--
-- 导出表中的数据 `xixia_site_templates`
--


</pre>
</body>
</html>
